class Animal{
    public String name;
    public int age;
    public double weight;

    public static String type = "mammal";

    public void sleep(){
        System.out.println(this.name+"正在睡觉");
    }

    public void eat(){
        System.out.println(this.name+"正在进食");
    }

    public void play(){
        System.out.println(this.name+"正在跟主人玩耍！");
    }

    public void show(){
        System.out.println(this.name +" "+ "今年" +this.age + "岁了 " + "体重 "+this.weight+"斤");
    }
}

class Cats extends Animal{
    public void mews(){
        System.out.println(this.name+" 喵喵喵~");
    }
}

class Dogs extends Animal{
    public void barks(){
        System.out.println(this.name+" 汪汪汪！");
    }
}
public class Text1 {
    public static void main(String[] args) {
        Cats cat = new Cats();
        cat.name = "hello kitty";
        cat.age = 2;
        cat.weight = 7;
        cat.mews();
        cat.eat();
        cat.play();
        cat.sleep();
        cat.show();

        Dogs dog = new Dogs();
        dog.name = "旺财";
        dog.age = 1;
        dog.weight = 8;
        dog.barks();
        dog.show();
        dog.eat();
        dog.play();
        dog.sleep();
    }
}
